package com.fei.yygh.hosp.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.fei.yygh.model.hosp.HospitalSet;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.fei.yygh.hosp.mapper.HospitalSetMapper;
import com.fei.yygh.hosp.service.HospitalSetService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class HospitalSetServiceImpl extends ServiceImpl<HospitalSetMapper, HospitalSet> implements HospitalSetService {


    //根据医院传递的编码进行查询
    @Override
    public Object getSignKey(String hoscode) {
        QueryWrapper<HospitalSet> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("hoscode", hoscode);
        HospitalSet getsets = baseMapper.selectOne(queryWrapper);
        //返回医院编码
        return getsets.getSignKey() ;
    }
}
